package com.easylinkin.linkappapi.asset.service;


import java.util.List;

import com.baomidou.mybatisplus.extension.service.IService;
import com.easylinkin.linkappapi.asset.entity.AssetRefDevice;

/**
 * <p>
 * 设备资产表，关联两张表 关联1  资产表-资产设备表 关联2  资产表-资产用户表 服务类
 * </p>
 *
 * @author XuGuoQing
 * @since 2020-04-15
 */
public interface AssetRefDeviceService extends IService<AssetRefDevice> {

    int batchDelete(List<String> assetId);

    /**
     * 删除指定资产的设备
     */
    void deleteByDeviceIds(String assetId, List<String> deviceIdList);

    boolean batchAdd(String assetId, List<String> deviceIdList);

    List<String> getExistedDeviceId(List<String> deviceIdList);

    //获得需要更新的设备列表
    List<String> isAssetRefDevices(String assetId, List<String> adddeviceIdList, List<String> deletedeviceIdList);

    /**
     * 查询设备id 根据资产id
     */
    List<String> getDeviceIdsByAssetId(String assetId);
}
